<!DOCTYPE html>
<html lang="zh">

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="keywords" content="">
    <meta name="description" content="">
    <title>修改终端管理</title>
    <link href="/static/css/bootstrap.min.css" rel="stylesheet" />
    <link rel="stylesheet" href="/static/include/css/style.css">
</head>

<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content" id="formBox">
    </div>
    <script id="formTpl" type="text/html">
		<form class="form-horizontal m" id="editForm" action="/admin/client/">
			<input id="id" name="id" type="hidden" value="{{d.id || ''}}" />
			<input type="hidden" name="oper" id="oper" value="{{d.oper || ''}}" />
			<div class="form-group">
				<label class="col-sm-3 control-label is-required">编号：</label>
				<div class="col-sm-8">
					{{# if(d.oper == "add"){ }}
					<input class="form-control" type="text" name="clientId" id="clientId" value="{{d.clientId || ''}}" maxlength="20" required>
					{{# }else{ }}
					<input class="form-control" type="text" name="clientId" id="clientId" value="{{d.clientId || ''}}" maxlength="20" required readonly>
					{{# } }}
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label is-required">密钥：</label>
				<div class="col-sm-8">
					<input class="form-control" type="text" name="clientSecret" id="clientSecret" value="{{d.clientSecret || ''}}"
						maxlength="50" required>
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label is-required">域：</label>
				<div class="col-sm-8">
					<input class="form-control" type="text" name="scope" id="scope" value="{{d.scope || ''}}"
						maxlength="50" required>
				</div>
			</div>
            <div class="form-group">
				<label class="col-sm-3 control-label is-required">自动放行：</label>
				<div class="col-sm-8">
					<div>
						{{# if(d.autoapprove == "true"){ }}
						<label class="radio-box"><input type="radio" name="autoapprove" value="true" checked /> 是</label>
						<label class="radio-box"><input type="radio" name="autoapprove" value="false"/> 否</label>
						{{# }else if(d.autoapprove == "false"){ }}
						<label class="radio-box"><input type="radio" name="autoapprove" value="true"/> 是</label>
						<label class="radio-box"><input type="radio" name="autoapprove" value="false" checked /> 否</label>
						{{# }else{ }}
						<label class="radio-box"><input type="radio" name="autoapprove" value="true"/> 是</label>
						<label class="radio-box"><input type="radio" name="autoapprove" value="false"/> 否</label>
						{{# } }}
					</div>
				</div>
			</div>
            <div class="form-group">
				<label class="col-sm-3 control-label is-required">授权模式：</label>
				<div class="col-sm-8">
					<div id="typeBox"></div>
				</div>
			</div>
            <div class="form-group">
				<label class="col-sm-3 control-label">令牌时效（秒）：</label>
				<div class="col-sm-8">
					<input class="form-control" type="text" name="accessTokenValidity" id="accessTokenValidity" value="{{d.accessTokenValidity || ''}}">
				</div>
			</div>
            <div class="form-group">
				<label class="col-sm-3 control-label">刷新时效（秒）：</label>
				<div class="col-sm-8">
					<input class="form-control" type="text" name="refreshTokenValidity" id="refreshTokenValidity" value="{{d.refreshTokenValidity || ''}}">
				</div>
			</div>
            <div class="form-group">
				<label class="col-sm-3 control-label">回调地址：</label>
				<div class="col-sm-8">
					<input class="form-control" type="text" name="webServerRedirectUri" id="webServerRedirectUri" value="{{d.webServerRedirectUri || ''}}"
						maxlength="50">
				</div>
			</div>
            <div class="form-group">
				<label class="col-sm-3 control-label">权限：</label>
				<div class="col-sm-8">
					<input class="form-control" type="text" name="authorities" id="authorities" value="{{d.authorities || ''}}"
						maxlength="50">
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">扩展信息：</label>
				<div class="col-sm-8">
					<textarea name="additionalInformation" maxlength="500"
						class="form-control">{{ d.additionalInformation || '' }}</textarea>
				</div>
			</div>
            <div class="form-group">
                安全属性
            </div>
            <div class="form-group">
				<label class="col-sm-3 control-label">验证码开关：</label>
				<div class="col-sm-8">
					<div>
						{{# if(d.captchaFlag == "1"){ }}
						<label class="radio-box"><input type="radio" name="captchaFlag" value="1" checked /> 开</label>
						<label class="radio-box"><input type="radio" name="captchaFlag" value="0"/> 关</label>
						{{# }else if(d.captchaFlag == "0"){ }}
						<label class="radio-box"><input type="radio" name="captchaFlag" value="1"/> 开</label>
						<label class="radio-box"><input type="radio" name="captchaFlag" value="0" checked /> 关</label>
						{{# }else{ }}
						<label class="radio-box"><input type="radio" name="captchaFlag" value="1"/> 开</label>
						<label class="radio-box"><input type="radio" name="captchaFlag" value="0"/> 关</label>
						{{# } }}
					</div>
				</div>
			</div>
            <div class="form-group">
				<label class="col-sm-3 control-label">前端密码加密：</label>
				<div class="col-sm-8">
					<div>
						{{# if(d.encFlag == "1"){ }}
						<label class="radio-box"><input type="radio" name="encFlag" value="1" checked /> 是</label>
						<label class="radio-box"><input type="radio" name="encFlag" value="0"/> 否</label>
						{{# }else if(d.encFlag == "0"){ }}
						<label class="radio-box"><input type="radio" name="encFlag" value="1"/> 是</label>
						<label class="radio-box"><input type="radio" name="encFlag" value="0" checked /> 否</label>
						{{# }else{ }}
						<label class="radio-box"><input type="radio" name="encFlag" value="1"/> 是</label>
						<label class="radio-box"><input type="radio" name="encFlag" value="0"/> 否</label>
						{{# } }}
					</div>
				</div>
			</div>
		</form>
    </script>
    <script src="/static/include/js/footer.js"></script>
    <script src="/static/pages/sysadm/client/clientEdit.js"></script>
</body>

</html>